def num_sum(num):
    if num == 1:
        return 1
    return num + num_sum(num-1)	#递归口

print(num_sum(3))